<html>
 <head>
  <meta charset="utf-8"/>
  <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport"/>
  <title>
   Emacs：最好的Python编辑器？  | 数螺 | NAUT IDEA
  </title>
  <link href="http://cdn.bootcss.com/bootstrap/3.3.6/css/bootstrap-theme.min.css" rel="stylesheet"/>
  <link href="http://cdn.bootcss.com/bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet"/>
  <style type="text/css">
   #xmain img {
                  max-width: 100%;
                  display: block;
                  margin-top: 10px;
                  margin-bottom: 10px;
                }

                #xmain p {
                    line-height:150%;
                    font-size: 16px;
                    margin-top: 20px;
                }

                #xmain h2 {
                    font-size: 24px;
                }

                #xmain h3 {
                    font-size: 20px;
                }

                #xmain h4 {
                    font-size: 18px;
                }


                .header {
	           background-color: #0099ff;
	           color: #ffffff;
	           margin-bottom: 20px;
	        }

	        .header p {
                  margin: 0px;
                  padding: 10px 0;
                  display: inline-block;  
                  vertical-align: middle;
                  font-size: 16px;
               }

               .header a {
                 color: white;
               }

              .header img {
                 height: 25px;
              }
  </style>
  <script src="http://cdn.bootcss.com/jquery/3.0.0/jquery.min.js">
  </script>
  <script src="http://nautstatic-10007657.file.myqcloud.com/static/css/readability.min.js" type="text/javascript">
  </script>
  <script type="text/javascript">
   $(document).ready(function() {
                 var loc = document.location;
                 var uri = {
                  spec: "http://dataunion.org/24134.html",
                  host: "http://dataunion.org",
                  prePath: "http://dataunion.org",
                  scheme: "http",
                  pathBase: "http://dataunion.org/"
                 };
    
                 var documentClone = document.cloneNode(true);
                 var article = new Readability(uri, documentClone).parse();
     
                 document.getElementById("xmain").innerHTML = article.content;
                });
  </script>
  <!-- 1466460638: Accept with keywords: (title(0.25):Python,编辑器,数盟,社区, topn(0.233333333333):插件,语言,插件包,数盟,行业资讯,数据挖掘,自带,网络接口,文件,自定义,示例,仓库,基础,模式,文章,社区,教程,python,环境,工具包,基础知识,语法,编辑器,虚拟环境,功能,编程语言,网站,代码,Python,按键).-->
 </head>
 <body onload="">
  <div class="header">
   <div class="container">
    <div class="row">
     <div class="col-xs-6 col-sm-6 text-left">
      <a href="/databee">
       <img src="http://nautidea-10007657.cos.myqcloud.com/logo_white.png"/>
      </a>
      <a href="/databee">
       <p>
        数螺
       </p>
      </a>
     </div>
     <div class="hidden-xs col-sm-6 text-right">
      <p>
       致力于数据科学的推广和知识传播
      </p>
     </div>
    </div>
   </div>
  </div>
  <div class="container text-center">
   <h1>
    Emacs：最好的Python编辑器？
   </h1>
  </div>
  <div class="container" id="xmain">
   ﻿﻿
   <title>
    Emacs：最好的Python编辑器？ | 数盟社区
   </title>
   <!-- All in One SEO Pack 2.2.7.6.2 by Michael Torbert of Semper Fi Web Design[32,66] -->
   <!-- /all in one seo pack -->
   <!--
<div align="center">
<a href="http://strata.oreilly.com.cn/hadoop-big-data-cn?cmp=mp-data-confreg-home-stcn16_dataunion_pc" target="_blank"><img src="http://dataunion.org/wp-content/uploads/2016/05/stratabj.jpg"/ ></a>
</div>
-->
   <header id="header-web">
    <div class="header-main">
     <hgroup class="logo">
      <h1>
       <a href="http://dataunion.org/" rel="home" title="数盟社区">
        <img src="http://dataunion.org/wp-content/themes/yzipi/images/logo.png"/>
       </a>
      </h1>
     </hgroup>
     <!--logo-->
     <nav class="header-nav">
      <ul class="menu" id="menu-%e4%b8%bb%e8%8f%9c%e5%8d%95">
       <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-has-children menu-item-71" id="menu-item-71">
        <a href="http://dataunion.org/category/events" title="events">
         活动
        </a>
        <ul class="sub-menu">
         <li class="menu-item menu-item-type-post_type menu-item-object-page menu-item-22457" id="menu-item-22457">
          <a href="http://dataunion.org/2016timeline">
           2016档期
          </a>
         </li>
         <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-22459" id="menu-item-22459">
          <a href="http://dataunion.org/category/parterc">
           合作会议
          </a>
         </li>
        </ul>
       </li>
       <li class="menu-item menu-item-type-taxonomy menu-item-object-category current-post-ancestor menu-item-has-children menu-item-20869" id="menu-item-20869">
        <a href="http://dataunion.org/category/tech" title="articles">
         文章
        </a>
        <ul class="sub-menu">
         <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-20867" id="menu-item-20867">
          <a href="http://dataunion.org/category/tech/base" title="base">
           基础架构
          </a>
         </li>
         <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-3302" id="menu-item-3302">
          <a href="http://dataunion.org/category/tech/ai" title="ai">
           人工智能
          </a>
         </li>
         <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-3303" id="menu-item-3303">
          <a href="http://dataunion.org/category/tech/analysis" title="analysis">
           数据分析
          </a>
         </li>
         <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-21920" id="menu-item-21920">
          <a href="http://dataunion.org/category/tech/dm">
           数据挖掘
          </a>
         </li>
         <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-3314" id="menu-item-3314">
          <a href="http://dataunion.org/category/tech/viz" title="viz">
           可视化
          </a>
         </li>
         <li class="menu-item menu-item-type-taxonomy menu-item-object-category current-post-ancestor current-menu-parent current-post-parent menu-item-3305" id="menu-item-3305">
          <a href="http://dataunion.org/category/tech/devl" title="devl">
           编程语言
          </a>
         </li>
        </ul>
       </li>
       <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-has-children menu-item-20876" id="menu-item-20876">
        <a href="http://dataunion.org/category/industry">
         行业
        </a>
        <ul class="sub-menu">
         <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-16328" id="menu-item-16328">
          <a href="http://dataunion.org/category/industry/case" title="case">
           行业应用
          </a>
         </li>
         <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-2112" id="menu-item-2112">
          <a href="http://dataunion.org/category/industry/demo" title="demo">
           Demo展示
          </a>
         </li>
         <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-21562" id="menu-item-21562">
          <a href="http://dataunion.org/category/industry/news">
           行业资讯
          </a>
         </li>
        </ul>
       </li>
       <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-311" id="menu-item-311">
        <a href="http://dataunion.org/category/sources" title="sources">
         资源
        </a>
       </li>
       <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-20870" id="menu-item-20870">
        <a href="http://dataunion.org/category/books" title="book">
         图书
        </a>
       </li>
       <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-21363" id="menu-item-21363">
        <a href="http://dataunion.org/category/training">
         课程
        </a>
       </li>
       <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-has-children menu-item-21853" id="menu-item-21853">
        <a href="http://dataunion.org/category/jobs">
         职位
        </a>
        <ul class="sub-menu">
         <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-22050" id="menu-item-22050">
          <a href="http://dataunion.org/category/career">
           职业规划
          </a>
         </li>
        </ul>
       </li>
      </ul>
     </nav>
     <!--header-nav-->
    </div>
   </header>
   <!--header-web-->
   <div id="main">
    <div id="soutab">
     <form action="http://dataunion.org/" class="search" method="get">
     </form>
    </div>
    <div id="container">
     <nav id="mbx">
      当前位置：
      <a href="http://dataunion.org">
       首页
      </a>
      &gt;
      <a href="http://dataunion.org/category/tech">
       文章
      </a>
      &gt;
      <a href="http://dataunion.org/category/tech/devl">
       编程语言
      </a>
      &gt;  正文
     </nav>
     <!--mbx-->
     <article class="content">
      <header align="centre" class="contenttitle">
       <div class="mscc">
        <h1 class="mscctitle">
         <a href="http://dataunion.org/24134.html">
          Emacs：最好的Python编辑器？
         </a>
        </h1>
        <address class="msccaddress ">
         <em>
          1,231 次阅读 -
         </em>
         <a href="http://dataunion.org/category/tech/devl" rel="category tag">
          编程语言
         </a>
        </address>
       </div>
      </header>
      <div class="content-text">
       <blockquote>
        <p>
         本文是
         <a href="https://realpython.com/blog/python/emacs-the-best-python-editor/">
          realpython.com
         </a>
         继《将Sublime Text 3打造为Python全栈开发环境》和
         <a href="http://codingpy.com/article/vim-and-python-match-in-heaven/">
          《Vim与Python真乃天作之合》
         </a>
         ，又一篇关于如何配置Python IDE的文章。这一次，主角变成了与Vim同样享有神器之称的Emacs编辑器。译者之前没有接触过Emacs，但是看完这篇文章之后，觉得与Vim和Sublime Text 3相比，最出彩的一个地方就是可以和IPython与Jupyter Notebook进行集成。按照本文的介绍配置完之后，确实会让Emacs成为一个异常强大的Python IDE。
        </p>
       </blockquote>
       <h2>
        安装与基础
       </h2>
       <h3>
        安装
       </h3>
       <p>
        Emacs安装不是本文的重点，因此，这里推荐大家参考
        <a href="http://ergoemacs.org/">
         ErgoEmacs
        </a>
        网站提供的
        <a href="http://ergoemacs.org/emacs/which_emacs.html">
         安装指南
        </a>
        ，完成在Linux、Mac或Windows平台的基本安装。安装完成之后，打开应用，你就会看到默认设置下地Emacs界面。
       </p>
       <p>
        <img src="https://realpython.com/images/blog_images/emacs/emacs-fresh-launch.png"/>
       </p>
       <h3>
        Emacs基础
       </h3>
       <p>
        同样，本文也不会过多介绍Emacs使用的基础知识。学习Emacs最容易的方法，就是通过其自带的教程。本文介绍的内容并不要求你知道如何使用Emacs；相反，本文的每一部分讲述的都是你学习基础知识后可以使用的。
       </p>
       <p>
        你可以使用方向键将光标移动到标有“Emacs Tutorial”字样的地方，然后按回车键，就可以打开自带教程。然后，你将会看到下面这段话：
       </p>
       <div>
        <!-- Crayon Syntax Highlighter v_2.7.2_beta -->
        <div class="crayon-syntax crayon-theme-classic crayon-font-monaco crayon-os-pc print-yes notranslate" data-settings=" minimize scroll-mouseover" id="crayon-576869d6e3476210962677" style=" margin-top: 12px; margin-bottom: 12px; font-size: 12px !important; line-height: 15px !important;">
         <div class="crayon-toolbar" data-settings=" mouseover overlay hide delay" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
          <span class="crayon-title">
          </span>
          <div class="crayon-tools" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
           <div class="crayon-button crayon-nums-button" title="切换是否显示行编号">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-plain-button" title="纯文本显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-wrap-button" title="切换自动换行">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-expand-button" title="点击展开代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-copy-button" title="复制代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-popup-button" title="在新窗口中显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
          </div>
         </div>
         <div class="crayon-info" style="min-height: 16.8px !important; line-height: 16.8px !important;">
         </div>
         <div class="crayon-plain-wrap">
          <textarea class="crayon-plain print-no" data-settings="dblclick" readonly="" style="-moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4; font-size: 12px !important; line-height: 15px !important;" wrap="soft">
           Emacs commands generally involve the CONTROL key (sometimes labeled
CTRL or CTL) or the META key (sometimes labeled EDIT or ALT).  Rather than
write that in full each time, we'll use the following abbreviations:

 C-&amp;lt;chr&amp;gt;&amp;lt;/chr&amp;gt;  means hold the CONTROL key while typing the character &amp;lt;chr&amp;gt;&amp;lt;/chr&amp;gt;
    Thus, C-f would be: hold the CONTROL key and type f.
 M-&amp;lt;chr&amp;gt;&amp;lt;/chr&amp;gt;  means hold the META or EDIT or ALT key down while typing &amp;lt;chr&amp;gt;.&amp;lt;/chr&amp;gt;
    If there is no META, EDIT or ALT key, instead press and release the
    ESC key and then type &amp;lt;chr&amp;gt;.&amp;lt;/chr&amp;gt;  We write &amp;lt;esc&amp;gt;&amp;lt;/esc&amp;gt; for the ESC key.
          </textarea>
         </div>
         <div class="crayon-main" style="">
          <table class="crayon-table">
           <tbody>
            <tr class="crayon-row">
             <td class="crayon-nums " data-settings="show">
              <div class="crayon-nums-content" style="font-size: 12px !important; line-height: 15px !important;">
               <div class="crayon-num" data-line="crayon-576869d6e3476210962677-1">
                1
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e3476210962677-2">
                2
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e3476210962677-3">
                3
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e3476210962677-4">
                4
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e3476210962677-5">
                5
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e3476210962677-6">
                6
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e3476210962677-7">
                7
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e3476210962677-8">
                8
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e3476210962677-9">
                9
               </div>
              </div>
             </td>
             <td class="crayon-code">
              <div class="crayon-pre" style="font-size: 12px !important; line-height: 15px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;">
               <div class="crayon-line" id="crayon-576869d6e3476210962677-1">
                <span class="crayon-e">
                 Emacs
                </span>
                <span class="crayon-e">
                 commands
                </span>
                <span class="crayon-e">
                 generally
                </span>
                <span class="crayon-e">
                 involve
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 CONTROL
                </span>
                <span class="crayon-e">
                 key
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 sometimes
                </span>
                <span class="crayon-e">
                 labeled
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e3476210962677-2">
                <span class="crayon-e">
                 CTRL
                </span>
                <span class="crayon-st">
                 or
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 CTL
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-st">
                 or
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 META
                </span>
                <span class="crayon-e">
                 key
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 sometimes
                </span>
                <span class="crayon-e">
                 labeled
                </span>
                <span class="crayon-e">
                 EDIT
                </span>
                <span class="crayon-st">
                 or
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 ALT
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 .
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 Rather
                </span>
                <span class="crayon-e">
                 than
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e3476210962677-3">
                <span class="crayon-e">
                 write
                </span>
                <span class="crayon-e">
                 that
                </span>
                <span class="crayon-st">
                 in
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 full
                </span>
                <span class="crayon-st">
                 each
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 time
                </span>
                <span class="crayon-sy">
                 ,
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-i">
                 we
                </span>
                '
                <span class="crayon-e">
                 ll
                </span>
                <span class="crayon-st">
                 use
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 following
                </span>
                <span class="crayon-v">
                 abbreviations
                </span>
                <span class="crayon-o">
                 :
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e3476210962677-4">
               </div>
               <div class="crayon-line" id="crayon-576869d6e3476210962677-5">
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 C
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 lt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-v">
                 chr
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 gt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 lt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-o">
                 /
                </span>
                <span class="crayon-v">
                 chr
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 gt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 means
                </span>
                <span class="crayon-e">
                 hold
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 CONTROL
                </span>
                <span class="crayon-e">
                 key
                </span>
                <span class="crayon-st">
                 while
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 typing
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-v">
                 character
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 lt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-v">
                 chr
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 gt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 lt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-o">
                 /
                </span>
                <span class="crayon-v">
                 chr
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 gt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e3476210962677-6">
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 Thus
                </span>
                <span class="crayon-sy">
                 ,
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 C
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 f
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 would
                </span>
                <span class="crayon-v">
                 be
                </span>
                <span class="crayon-o">
                 :
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 hold
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 CONTROL
                </span>
                <span class="crayon-e">
                 key
                </span>
                <span class="crayon-st">
                 and
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-i">
                 type
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 f
                </span>
                <span class="crayon-sy">
                 .
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e3476210962677-7">
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 M
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 lt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-v">
                 chr
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 gt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 lt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-o">
                 /
                </span>
                <span class="crayon-v">
                 chr
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 gt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 means
                </span>
                <span class="crayon-e">
                 hold
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 META
                </span>
                <span class="crayon-st">
                 or
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 EDIT
                </span>
                <span class="crayon-st">
                 or
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 ALT
                </span>
                <span class="crayon-e">
                 key
                </span>
                <span class="crayon-e">
                 down
                </span>
                <span class="crayon-st">
                 while
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 typing
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 lt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-v">
                 chr
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 gt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 .
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 lt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-o">
                 /
                </span>
                <span class="crayon-v">
                 chr
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 gt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e3476210962677-8">
                <span class="crayon-h">
                </span>
                <span class="crayon-st">
                 If
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 there
                </span>
                <span class="crayon-st">
                 is
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 no
                </span>
                <span class="crayon-v">
                 META
                </span>
                <span class="crayon-sy">
                 ,
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 EDIT
                </span>
                <span class="crayon-st">
                 or
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 ALT
                </span>
                <span class="crayon-v">
                 key
                </span>
                <span class="crayon-sy">
                 ,
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 instead
                </span>
                <span class="crayon-e">
                 press
                </span>
                <span class="crayon-st">
                 and
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 release
                </span>
                <span class="crayon-e">
                 the
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e3476210962677-9">
                <span class="crayon-e">
                </span>
                <span class="crayon-e">
                 ESC
                </span>
                <span class="crayon-e">
                 key
                </span>
                <span class="crayon-st">
                 and
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-st">
                 then
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 type
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 lt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-v">
                 chr
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 gt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 .
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 lt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-o">
                 /
                </span>
                <span class="crayon-v">
                 chr
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 gt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 We
                </span>
                <span class="crayon-v">
                 write
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 lt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-v">
                 esc
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 gt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 lt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-o">
                 /
                </span>
                <span class="crayon-v">
                 esc
                </span>
                <span class="crayon-o">
                 &amp;
                </span>
                <span class="crayon-v">
                 gt
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-st">
                 for
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 ESC
                </span>
                <span class="crayon-v">
                 key
                </span>
                <span class="crayon-sy">
                 .
                </span>
               </div>
              </div>
             </td>
            </tr>
           </tbody>
          </table>
         </div>
        </div>
        <!-- [Format Time: 0.0444 seconds] -->
       </div>
       <p>
        接下来，本文还会继续出现类似
        <code>
         C-x C-s
        </code>
        等按键命令。这些命令表示，要同时按下Control键和x键，然后再同时按下Control和s键。这正是使用Emacs编辑器的基本形式。了解更多基础知识，你可以学习自带教程或者GNU网站提供的这个教程
        <a href="http://www.gnu.org/software/emacs/tour/">
         Guided Tour of Emacs
        </a>
        。
       </p>
       <h3>
        配置与插件包（packages）
       </h3>
       <p>
        Emacs的好处之一，就是配置简单。Emacs配置的核心则是初始化文件（Initialization File）——
        <code>
         init.el
        </code>
        。
       </p>
       <p>
        在Unix环境下，这个文件应该放置在
        <code>
         $HOME/.emacs.d/init.el
        </code>
        路径。
       </p>
       <div>
        <!-- Crayon Syntax Highlighter v_2.7.2_beta -->
        <div class="crayon-syntax crayon-theme-classic crayon-font-monaco crayon-os-pc print-yes notranslate" data-settings=" minimize scroll-mouseover" id="crayon-576869d6e3487292431509" style=" margin-top: 12px; margin-bottom: 12px; font-size: 12px !important; line-height: 15px !important;">
         <div class="crayon-toolbar" data-settings=" mouseover overlay hide delay" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
          <span class="crayon-title">
          </span>
          <div class="crayon-tools" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
           <div class="crayon-button crayon-nums-button" title="切换是否显示行编号">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-plain-button" title="纯文本显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-wrap-button" title="切换自动换行">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-expand-button" title="点击展开代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-copy-button" title="复制代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-popup-button" title="在新窗口中显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
          </div>
         </div>
         <div class="crayon-info" style="min-height: 16.8px !important; line-height: 16.8px !important;">
         </div>
         <div class="crayon-plain-wrap">
          <textarea class="crayon-plain print-no" data-settings="dblclick" readonly="" style="-moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4; font-size: 12px !important; line-height: 15px !important;" wrap="soft">
           $ touch ~/.emacs.d/init.el
          </textarea>
         </div>
         <div class="crayon-main" style="">
          <table class="crayon-table">
           <tbody>
            <tr class="crayon-row">
             <td class="crayon-nums " data-settings="show">
              <div class="crayon-nums-content" style="font-size: 12px !important; line-height: 15px !important;">
               <div class="crayon-num" data-line="crayon-576869d6e3487292431509-1">
                1
               </div>
              </div>
             </td>
             <td class="crayon-code">
              <div class="crayon-pre" style="font-size: 12px !important; line-height: 15px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;">
               <div class="crayon-line" id="crayon-576869d6e3487292431509-1">
                <span class="crayon-sy">
                 $
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 touch
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-o">
                 ~
                </span>
                <span class="crayon-o">
                 /
                </span>
                <span class="crayon-sy">
                 .
                </span>
                <span class="crayon-v">
                 emacs
                </span>
                <span class="crayon-sy">
                 .
                </span>
                <span class="crayon-v">
                 d
                </span>
                <span class="crayon-o">
                 /
                </span>
                <span class="crayon-v">
                 init
                </span>
                <span class="crayon-sy">
                 .
                </span>
                <span class="crayon-v">
                 el
                </span>
               </div>
              </div>
             </td>
            </tr>
           </tbody>
          </table>
         </div>
        </div>
        <!-- [Format Time: 0.0009 seconds] -->
       </div>
       <p>
        同时，在Windows平台，如果没有设置
        <code>
         HOME
        </code>
        环境变量，该文件应该放置在
        <code>
         C:/.emacs.d/init.el
        </code>
        路径。
       </p>
       <blockquote>
        <p>
         本文将会与大家分享许多配置示例。那么如果你想继续跟随本文进行配置的话，请先创建init文件。如果不想的话，可以在结语部分直接查看最终的完整init文件。
        </p>
       </blockquote>
       <p>
        插件包（packages）可以对Emacs进行自定义，需要从不同的代码仓库获取。其中，最主要的Emacs插件包仓库是
        <code>
         MELPA
        </code>
        仓库。本文中提到的所有插件包都将从该仓库获取并安装。
       </p>
       <h3>
        样式（主题&amp;更多）
       </h3>
       <p>
        首先，下面是一个插件包安装示例代码，其中安装了一个主题插件。
       </p>
       <div>
        <!-- Crayon Syntax Highlighter v_2.7.2_beta -->
        <div class="crayon-syntax crayon-theme-classic crayon-font-monaco crayon-os-pc print-yes notranslate" data-settings=" minimize scroll-mouseover" id="crayon-576869d6e348f201839048" style=" margin-top: 12px; margin-bottom: 12px; font-size: 12px !important; line-height: 15px !important;">
         <div class="crayon-toolbar" data-settings=" mouseover overlay hide delay" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
          <span class="crayon-title">
          </span>
          <div class="crayon-tools" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
           <div class="crayon-button crayon-nums-button" title="切换是否显示行编号">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-plain-button" title="纯文本显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-wrap-button" title="切换自动换行">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-expand-button" title="点击展开代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-copy-button" title="复制代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-popup-button" title="在新窗口中显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
          </div>
         </div>
         <div class="crayon-info" style="min-height: 16.8px !important; line-height: 16.8px !important;">
         </div>
         <div class="crayon-plain-wrap">
          <textarea class="crayon-plain print-no" data-settings="dblclick" readonly="" style="-moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4; font-size: 12px !important; line-height: 15px !important;" wrap="soft">
           ;; init.el --- Emacs configuration

;; INSTALL PACKAGES
;; --------------------------------------

(require 'package)

(add-to-list 'package-archives
       '("melpa" . "http://melpa.org/packages/") t)

(package-initialize)
(when (not package-archive-contents)
  (package-refresh-contents))

(defvar myPackages
  '(better-defaults
    material-theme))

(mapc #'(lambda (package)
    (unless (package-installed-p package)
      (package-install package)))
      myPackages)

;; BASIC CUSTOMIZATION
;; --------------------------------------

(setq inhibit-startup-message t) ;; hide the startup message
(load-theme 'material t) ;; load material theme
(global-linum-mode t) ;; enable line numbers globally

;; init.el ends here
          </textarea>
         </div>
         <div class="crayon-main" style="">
          <table class="crayon-table">
           <tbody>
            <tr class="crayon-row">
             <td class="crayon-nums " data-settings="show">
              <div class="crayon-nums-content" style="font-size: 12px !important; line-height: 15px !important;">
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-1">
                1
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-2">
                2
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-3">
                3
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-4">
                4
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-5">
                5
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-6">
                6
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-7">
                7
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-8">
                8
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-9">
                9
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-10">
                10
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-11">
                11
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-12">
                12
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-13">
                13
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-14">
                14
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-15">
                15
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-16">
                16
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-17">
                17
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-18">
                18
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-19">
                19
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-20">
                20
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-21">
                21
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-22">
                22
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-23">
                23
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-24">
                24
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-25">
                25
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-26">
                26
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-27">
                27
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-28">
                28
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-29">
                29
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e348f201839048-30">
                30
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e348f201839048-31">
                31
               </div>
              </div>
             </td>
             <td class="crayon-code">
              <div class="crayon-pre" style="font-size: 12px !important; line-height: 15px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;">
               <div class="crayon-line" id="crayon-576869d6e348f201839048-1">
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 init
                </span>
                <span class="crayon-sy">
                 .
                </span>
                <span class="crayon-v">
                 el
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 Emacs
                </span>
                <span class="crayon-i">
                 configuration
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-2">
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-3">
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 INSTALL
                </span>
                <span class="crayon-i">
                 PACKAGES
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-4">
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-5">
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-6">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-i">
                 require
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-s">
                 'package)
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-7">
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-8">
                <span class="crayon-s">
                 (add-to-list '
                </span>
                <span class="crayon-t">
                 package
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 archives
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-9">
                <span class="crayon-h">
                </span>
                <span class="crayon-s">
                 '("melpa" . "http://melpa.org/packages/") t)
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-10">
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-11">
                <span class="crayon-s">
                 (package-initialize)
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-12">
                <span class="crayon-s">
                 (when (not package-archive-contents)
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-13">
                <span class="crayon-s">
                 (package-refresh-contents))
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-14">
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-15">
                <span class="crayon-s">
                 (defvar myPackages
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-16">
                <span class="crayon-s">
                 '
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-v">
                 better
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 defaults
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-17">
                <span class="crayon-e">
                </span>
                <span class="crayon-v">
                 material
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 theme
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-18">
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-19">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-v">
                 mapc
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-p">
                 #'(lambda (package)
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-20">
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 unless
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-t">
                 package
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 installed
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 p
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-t">
                 package
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-21">
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-t">
                 package
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 install
                </span>
                <span class="crayon-t">
                 package
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-22">
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 myPackages
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-23">
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-24">
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 BASIC
                </span>
                <span class="crayon-i">
                 CUSTOMIZATION
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-25">
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-26">
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-27">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 setq
                </span>
                <span class="crayon-v">
                 inhibit
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 startup
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 message
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 t
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 hide
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 startup
                </span>
                <span class="crayon-e">
                 message
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-28">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-v">
                 load
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 theme
                </span>
                <span class="crayon-h">
                </span>
                '
                <span class="crayon-i">
                 material
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 t
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 load
                </span>
                <span class="crayon-e">
                 material
                </span>
                <span class="crayon-e">
                 theme
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-29">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-m">
                 global
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 linum
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 mode
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 t
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 enable
                </span>
                <span class="crayon-e">
                 line
                </span>
                <span class="crayon-e">
                 numbers
                </span>
                <span class="crayon-i">
                 globally
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e348f201839048-30">
               </div>
               <div class="crayon-line" id="crayon-576869d6e348f201839048-31">
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 init
                </span>
                <span class="crayon-sy">
                 .
                </span>
                <span class="crayon-e">
                 el
                </span>
                <span class="crayon-e">
                 ends
                </span>
                <span class="crayon-v">
                 here
                </span>
               </div>
              </div>
             </td>
            </tr>
           </tbody>
          </table>
         </div>
        </div>
        <!-- [Format Time: 0.0305 seconds] -->
       </div>
       <p>
        配置示例代码的第一部分是
        <code>
         ;; INSTALL PACKAGES
        </code>
        ，安装了
        <code>
         better-defaults
        </code>
        和
        <code>
         material-theme
        </code>
        共两个插件包。
        <code>
         better-defaults
        </code>
        插件集合了一系列对Emacs默认配置的修改，为我们开始进一步自定义奠定了良好的基础。
        <code>
         material-theme
        </code>
        插件则提供了一组自定义的样式。
       </p>
       <blockquote>
        <p>
         主题插件中，我个人更喜欢的就是这个
         <code>
          material-theme
         </code>
         插件，所以本文中我们将一直使用这个插件。
        </p>
       </blockquote>
       <p>
        第二部分则是
        <code>
         ;; BASIC CUSTOMIZATION
        </code>
        （基本自定义）。
       </p>
       <ol>
        <li>
         禁用启动消息（即显示所有教程信息的页面）。在你更熟悉Emacs之前，你可以不禁用。
        </li>
        <li>
         加载
         <code>
          material
         </code>
         主题。
        </li>
        <li>
         启用全局显示行号
        </li>
       </ol>
       <p>
        全局启用意味着这个功能对于Emacs打开的所有缓冲区（buffers）都适用。所以，如果你打开了Python文件、markdown文件或者是纯文本文件，它们都将显示行号。你还可以根据不同的模式（mode）启用不同的功能，——例如，python模式、markdown模式和纯文本模式。稍后我们将Emacs配置为Python IDE时还会讲到。
       </p>
       <p>
        现在我们已经有了一个完整的基础配置文件，可以重启Emacs，观察变化。如果你将
        <code>
         init.el
        </code>
        文件放在了正确地路径中，Emacs将会自动加载该文件。
       </p>
       <p>
        另外，你也可以在命令行输入
        <code>
         emacs -q --load &lt;path to init.el&gt;
        </code>
        命令，启动Emacs。配置文件加载完成后，我们之前见到的Emacs窗口会变得更好看：
       </p>
       <p>
        <img src="https://realpython.com/images/blog_images/emacs/emacs-themed.png"/>
       </p>
       <p>
        下面这张图展示了一些Emacs本身自带的基础功能——包括简单的文件检索和Split Layouts。
       </p>
       <p>
        <img src="https://realpython.com/images/blog_images/emacs/emacs-simple-features.png"/>
       </p>
       <p>
        我最喜欢的一个Emacs基础功能，就是可以进行快速的递归文本检索（recursive grep search）——
        <code>
         M-x rgrep
        </code>
        。举个例子，假如你想在某个文件夹下以
        <code>
         .md
        </code>
        为扩展名的文件中，查找所有出现过
        <code>
         python
        </code>
        一词的段落：
       </p>
       <p>
        <img src="https://realpython.com/images/blog_images/emacs/emacs-rgrep.gif"/>
       </p>
       <p>
        完成基础配置之后，我们可以开始将Emacs配置为Python开发环境啦！
       </p>
       <h2>
        Elpy ——Python开发
       </h2>
       <p>
        Emacs自带的python模式（python.el）支持缩进和语法高亮功能。。但是如果要与专门针对Python设计的IDE竞争的话，我们肯定还需要添加更多的功能。
        <code>
         elpy
        </code>
        （Emacs Lisp Python Environment）插件可以说为我们提供了Python开发环境所需要的几乎全部功能，包括：
       </p>
       <ul>
        <li>
         自动缩进
        </li>
        <li>
         语法高亮
        </li>
        <li>
         自动补全
        </li>
        <li>
         语法检查
        </li>
        <li>
         REPL集成
        </li>
        <li>
         虚拟环境支持，以及
        </li>
        <li>
         更多其他功能
        </li>
       </ul>
       <p>
        要想安装并启用
        <code>
         elpy
        </code>
        插件，我们需要进行一些配置，并使用你自己喜欢的方式（例如，
        <code>
         pip
        </code>
        或
        <code>
         conda
        </code>
        ）安装
        <code>
         flake8
        </code>
        和
        <code>
         jedi
        </code>
        这两个Python工具包。
       </p>
       <p>
        下面的配置可以安装
        <code>
         elpy
        </code>
        插件包：
       </p>
       <div>
        <!-- Crayon Syntax Highlighter v_2.7.2_beta -->
        <div class="crayon-syntax crayon-theme-classic crayon-font-monaco crayon-os-pc print-yes notranslate" data-settings=" minimize scroll-mouseover" id="crayon-576869d6e3499280282504" style=" margin-top: 12px; margin-bottom: 12px; font-size: 12px !important; line-height: 15px !important;">
         <div class="crayon-toolbar" data-settings=" mouseover overlay hide delay" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
          <span class="crayon-title">
          </span>
          <div class="crayon-tools" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
           <div class="crayon-button crayon-nums-button" title="切换是否显示行编号">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-plain-button" title="纯文本显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-wrap-button" title="切换自动换行">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-expand-button" title="点击展开代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-copy-button" title="复制代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-popup-button" title="在新窗口中显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
          </div>
         </div>
         <div class="crayon-info" style="min-height: 16.8px !important; line-height: 16.8px !important;">
         </div>
         <div class="crayon-plain-wrap">
          <textarea class="crayon-plain print-no" data-settings="dblclick" readonly="" style="-moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4; font-size: 12px !important; line-height: 15px !important;" wrap="soft">
           (defvar myPackages
  '(better-defaults
    elpy ;; add the elpy package
    material-theme))
          </textarea>
         </div>
         <div class="crayon-main" style="">
          <table class="crayon-table">
           <tbody>
            <tr class="crayon-row">
             <td class="crayon-nums " data-settings="show">
              <div class="crayon-nums-content" style="font-size: 12px !important; line-height: 15px !important;">
               <div class="crayon-num" data-line="crayon-576869d6e3499280282504-1">
                1
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e3499280282504-2">
                2
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e3499280282504-3">
                3
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e3499280282504-4">
                4
               </div>
              </div>
             </td>
             <td class="crayon-code">
              <div class="crayon-pre" style="font-size: 12px !important; line-height: 15px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;">
               <div class="crayon-line" id="crayon-576869d6e3499280282504-1">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 defvar
                </span>
                <span class="crayon-i">
                 myPackages
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e3499280282504-2">
                <span class="crayon-h">
                </span>
                '
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-v">
                 better
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 defaults
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e3499280282504-3">
                <span class="crayon-e">
                </span>
                <span class="crayon-i">
                 elpy
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 add
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 elpy
                </span>
                <span class="crayon-t">
                 package
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e3499280282504-4">
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 material
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 theme
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
              </div>
             </td>
            </tr>
           </tbody>
          </table>
         </div>
        </div>
        <!-- [Format Time: 0.0163 seconds] -->
       </div>
       <p>
        现在我们这样启用这个插件：
       </p>
       <p>
        完成上面的配置之后，我们可以重启Emacs，并打开一个Python文件，就可以查看新的配置是否生效。
       </p>
       <p>
        <img src="http://gold.xitu.io/images/loading.png"/>
       </p>
       <p>
        上面这幅图中显示了以下几种功能：
       </p>
       <ul>
        <li>
         自动缩进
        </li>
        <li>
         语法高亮
        </li>
        <li>
         语法检查（第三行的错误提示）
        </li>
        <li>
         自动补全（第九行显示的列表方法）
        </li>
       </ul>
       <p>
        另外，假设我们想要运行这个脚本。在Python自带的IDLE或Sublime Text中，你可以点击一个运行当前脚本的按钮。Emacs编辑器也是一样，不过我们只需要Python缓冲区按下
        <code>
         C-c C-c
        </code>
        即可。
       </p>
       <p>
        <img src="https://realpython.com/images/blog_images/emacs/emacs-elpy-execute.png"/>
       </p>
       <p>
        通常，我们会希望运行一个虚拟环境，然后再使用虚拟环境中安装的工具包来执行代码。要想在Emacs中使用虚拟环境，我们需要输入
        <code>
         M-x pyvenv-activate
        </code>
        ，然后根据提示操作。输入
        <code>
         M-x pyvenv-deactivate
        </code>
        就可以关闭虚拟环境。Elpy插件还提供了调试虚拟环境、处理elpy插件可能出现的问题的接口。输入
        <code>
         M-x elpy-config
        </code>
        ，就会出现下面的信息，其中包含了有价值的调试信息。
       </p>
       <p>
        <img src="https://realpython.com/images/blog_images/emacs/emacs-elpy-config.png"/>
       </p>
       <p>
        到这里，我们已经介绍完在Emacs中实现Python IDE基础功能的方法。接下来，我们来进一步完善Emacs的配置。
       </p>
       <h2>
        额外的Python功能
       </h2>
       <p>
        除了上面介绍的基本IDE功能之外，Emacs还针对Python语言提供了一些额外的功能。在这一部分，我们无法介绍全部的额外功能，但是肯定会涉及PEP8、IPython/Jupyter集成。不过在此之前，我们要快速梳理一下语法检查配置。
       </p>
       <h3>
        更好的语法检查（Flycheck v. Flymake）
       </h3>
       <p>
        默认情况下，安装了Elpy插件的Emacs提供一个名叫
        <code>
         Flymake
        </code>
        的语法检查插件。但是，我们还可以选择另外一个名叫
        <code>
         Flycheck
        </code>
        的插件，后者支持实时语法检查。幸运地是，从
        <code>
         Flymake
        </code>
        切换至
        <code>
         Flycheck
        </code>
        非常简单：
       </p>
       <div>
        <!-- Crayon Syntax Highlighter v_2.7.2_beta -->
        <div class="crayon-syntax crayon-theme-classic crayon-font-monaco crayon-os-pc print-yes notranslate" data-settings=" minimize scroll-mouseover" id="crayon-576869d6e34a1925840836" style=" margin-top: 12px; margin-bottom: 12px; font-size: 12px !important; line-height: 15px !important;">
         <div class="crayon-toolbar" data-settings=" mouseover overlay hide delay" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
          <span class="crayon-title">
          </span>
          <div class="crayon-tools" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
           <div class="crayon-button crayon-nums-button" title="切换是否显示行编号">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-plain-button" title="纯文本显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-wrap-button" title="切换自动换行">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-expand-button" title="点击展开代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-copy-button" title="复制代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-popup-button" title="在新窗口中显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
          </div>
         </div>
         <div class="crayon-info" style="min-height: 16.8px !important; line-height: 16.8px !important;">
         </div>
         <div class="crayon-plain-wrap">
          <textarea class="crayon-plain print-no" data-settings="dblclick" readonly="" style="-moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4; font-size: 12px !important; line-height: 15px !important;" wrap="soft">
           (defvar myPackages
  '(better-defaults
    elpy
    flycheck ;; add the flycheck package
    material-theme))
          </textarea>
         </div>
         <div class="crayon-main" style="">
          <table class="crayon-table">
           <tbody>
            <tr class="crayon-row">
             <td class="crayon-nums " data-settings="show">
              <div class="crayon-nums-content" style="font-size: 12px !important; line-height: 15px !important;">
               <div class="crayon-num" data-line="crayon-576869d6e34a1925840836-1">
                1
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34a1925840836-2">
                2
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34a1925840836-3">
                3
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34a1925840836-4">
                4
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34a1925840836-5">
                5
               </div>
              </div>
             </td>
             <td class="crayon-code">
              <div class="crayon-pre" style="font-size: 12px !important; line-height: 15px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;">
               <div class="crayon-line" id="crayon-576869d6e34a1925840836-1">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 defvar
                </span>
                <span class="crayon-i">
                 myPackages
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34a1925840836-2">
                <span class="crayon-h">
                </span>
                '
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-v">
                 better
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 defaults
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34a1925840836-3">
                <span class="crayon-e">
                </span>
                <span class="crayon-e">
                 elpy
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34a1925840836-4">
                <span class="crayon-e">
                </span>
                <span class="crayon-i">
                 flycheck
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 add
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 flycheck
                </span>
                <span class="crayon-t">
                 package
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34a1925840836-5">
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 material
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 theme
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
              </div>
             </td>
            </tr>
           </tbody>
          </table>
         </div>
        </div>
        <!-- [Format Time: 0.0014 seconds] -->
       </div>
       <div>
        <!-- Crayon Syntax Highlighter v_2.7.2_beta -->
        <div class="crayon-syntax crayon-theme-classic crayon-font-monaco crayon-os-pc print-yes notranslate" data-settings=" minimize scroll-mouseover" id="crayon-576869d6e34a8129134292" style=" margin-top: 12px; margin-bottom: 12px; font-size: 12px !important; line-height: 15px !important;">
         <div class="crayon-toolbar" data-settings=" mouseover overlay hide delay" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
          <span class="crayon-title">
          </span>
          <div class="crayon-tools" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
           <div class="crayon-button crayon-nums-button" title="切换是否显示行编号">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-plain-button" title="纯文本显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-wrap-button" title="切换自动换行">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-expand-button" title="点击展开代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-copy-button" title="复制代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-popup-button" title="在新窗口中显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
          </div>
         </div>
         <div class="crayon-info" style="min-height: 16.8px !important; line-height: 16.8px !important;">
         </div>
         <div class="crayon-plain-wrap">
          <textarea class="crayon-plain print-no" data-settings="dblclick" readonly="" style="-moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4; font-size: 12px !important; line-height: 15px !important;" wrap="soft">
           (when (require 'flycheck nil t)
  (setq elpy-modules (delq 'elpy-module-flymake elpy-modules))
  (add-hook 'elpy-mode-hook 'flycheck-mode))
          </textarea>
         </div>
         <div class="crayon-main" style="">
          <table class="crayon-table">
           <tbody>
            <tr class="crayon-row">
             <td class="crayon-nums " data-settings="show">
              <div class="crayon-nums-content" style="font-size: 12px !important; line-height: 15px !important;">
               <div class="crayon-num" data-line="crayon-576869d6e34a8129134292-1">
                1
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34a8129134292-2">
                2
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34a8129134292-3">
                3
               </div>
              </div>
             </td>
             <td class="crayon-code">
              <div class="crayon-pre" style="font-size: 12px !important; line-height: 15px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;">
               <div class="crayon-line" id="crayon-576869d6e34a8129134292-1">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 when
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-i">
                 require
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-s">
                 'flycheck nil t)
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34a8129134292-2">
                <span class="crayon-s">
                 (setq elpy-modules (delq '
                </span>
                <span class="crayon-v">
                 elpy
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 module
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 flymake
                </span>
                <span class="crayon-v">
                 elpy
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 modules
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34a8129134292-3">
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-v">
                 add
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 hook
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-s">
                 'elpy-mode-hook '
                </span>
                <span class="crayon-v">
                 flycheck
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 mode
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
              </div>
             </td>
            </tr>
           </tbody>
          </table>
         </div>
        </div>
        <!-- [Format Time: 0.0075 seconds] -->
       </div>
       <p>
        现在，我们就可以在编辑Python代码的同时，获得实时代码检查反馈了：
       </p>
       <p>
        <img src="http://gold.xitu.io/images/loading.png"/>
       </p>
       <h3>
        遵循PEP8规范
       </h3>
       <p>
        不管你喜不喜欢，PEP8都不会消失。如果你想遵循PEP8标准的全部或部分规范，你大概希望能够实现自动化合规。
        <code>
         autopep8
        </code>
        插件就是解决之道。这个插件与Emacs无缝集成，因此当你保存文件时——
        <code>
         C-x C-s
        </code>
        ——autopep8插件就会自动格式化代码，并纠正所有不符合PEP8标准的错误（排除你不希望检查的错误）。
       </p>
       <p>
        首先，你需要通过你喜欢的方式安装
        <code>
         autopep8
        </code>
        这个Python工具包，然后添加下面的Emacs配置代码：
       </p>
       <div>
        <!-- Crayon Syntax Highlighter v_2.7.2_beta -->
        <div class="crayon-syntax crayon-theme-classic crayon-font-monaco crayon-os-pc print-yes notranslate" data-settings=" minimize scroll-mouseover" id="crayon-576869d6e34af040707650" style=" margin-top: 12px; margin-bottom: 12px; font-size: 12px !important; line-height: 15px !important;">
         <div class="crayon-toolbar" data-settings=" mouseover overlay hide delay" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
          <span class="crayon-title">
          </span>
          <div class="crayon-tools" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
           <div class="crayon-button crayon-nums-button" title="切换是否显示行编号">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-plain-button" title="纯文本显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-wrap-button" title="切换自动换行">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-expand-button" title="点击展开代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-copy-button" title="复制代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-popup-button" title="在新窗口中显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
          </div>
         </div>
         <div class="crayon-info" style="min-height: 16.8px !important; line-height: 16.8px !important;">
         </div>
         <div class="crayon-plain-wrap">
          <textarea class="crayon-plain print-no" data-settings="dblclick" readonly="" style="-moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4; font-size: 12px !important; line-height: 15px !important;" wrap="soft">
           (defvar myPackages
  '(better-defaults
    elpy
    flycheck
    material-theme
    py-autopep8)) ;; add the autopep8 package
          </textarea>
         </div>
         <div class="crayon-main" style="">
          <table class="crayon-table">
           <tbody>
            <tr class="crayon-row">
             <td class="crayon-nums " data-settings="show">
              <div class="crayon-nums-content" style="font-size: 12px !important; line-height: 15px !important;">
               <div class="crayon-num" data-line="crayon-576869d6e34af040707650-1">
                1
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34af040707650-2">
                2
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34af040707650-3">
                3
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34af040707650-4">
                4
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34af040707650-5">
                5
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34af040707650-6">
                6
               </div>
              </div>
             </td>
             <td class="crayon-code">
              <div class="crayon-pre" style="font-size: 12px !important; line-height: 15px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;">
               <div class="crayon-line" id="crayon-576869d6e34af040707650-1">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 defvar
                </span>
                <span class="crayon-i">
                 myPackages
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34af040707650-2">
                <span class="crayon-h">
                </span>
                '
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-v">
                 better
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 defaults
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34af040707650-3">
                <span class="crayon-e">
                </span>
                <span class="crayon-e">
                 elpy
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34af040707650-4">
                <span class="crayon-e">
                </span>
                <span class="crayon-e">
                 flycheck
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34af040707650-5">
                <span class="crayon-e">
                </span>
                <span class="crayon-v">
                 material
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 theme
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34af040707650-6">
                <span class="crayon-e">
                </span>
                <span class="crayon-v">
                 py
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 autopep8
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 add
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 autopep8
                </span>
                <span class="crayon-t">
                 package
                </span>
               </div>
              </div>
             </td>
            </tr>
           </tbody>
          </table>
         </div>
        </div>
        <!-- [Format Time: 0.0014 seconds] -->
       </div>
       <div>
        <!-- Crayon Syntax Highlighter v_2.7.2_beta -->
        <div class="crayon-syntax crayon-theme-classic crayon-font-monaco crayon-os-pc print-yes notranslate" data-settings=" minimize scroll-mouseover" id="crayon-576869d6e34b5170329815" style=" margin-top: 12px; margin-bottom: 12px; font-size: 12px !important; line-height: 15px !important;">
         <div class="crayon-toolbar" data-settings=" mouseover overlay hide delay" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
          <span class="crayon-title">
          </span>
          <div class="crayon-tools" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
           <div class="crayon-button crayon-nums-button" title="切换是否显示行编号">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-plain-button" title="纯文本显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-wrap-button" title="切换自动换行">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-expand-button" title="点击展开代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-copy-button" title="复制代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-popup-button" title="在新窗口中显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
          </div>
         </div>
         <div class="crayon-info" style="min-height: 16.8px !important; line-height: 16.8px !important;">
         </div>
         <div class="crayon-plain-wrap">
          <textarea class="crayon-plain print-no" data-settings="dblclick" readonly="" style="-moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4; font-size: 12px !important; line-height: 15px !important;" wrap="soft">
           (require 'py-autopep8)
(add-hook 'elpy-mode-hook 'py-autopep8-enable-on-save)
          </textarea>
         </div>
         <div class="crayon-main" style="">
          <table class="crayon-table">
           <tbody>
            <tr class="crayon-row">
             <td class="crayon-nums " data-settings="show">
              <div class="crayon-nums-content" style="font-size: 12px !important; line-height: 15px !important;">
               <div class="crayon-num" data-line="crayon-576869d6e34b5170329815-1">
                1
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34b5170329815-2">
                2
               </div>
              </div>
             </td>
             <td class="crayon-code">
              <div class="crayon-pre" style="font-size: 12px !important; line-height: 15px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;">
               <div class="crayon-line" id="crayon-576869d6e34b5170329815-1">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-i">
                 require
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-s">
                 'py-autopep8)
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34b5170329815-2">
                <span class="crayon-s">
                 (add-hook '
                </span>
                <span class="crayon-v">
                 elpy
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 mode
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 hook
                </span>
                <span class="crayon-h">
                </span>
                '
                <span class="crayon-v">
                 py
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 autopep8
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 enable
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 on
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 save
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
              </div>
             </td>
            </tr>
           </tbody>
          </table>
         </div>
        </div>
        <!-- [Format Time: 0.0011 seconds] -->
       </div>
       <p>
        现在我们保存Python示例文件，Autopep8插件就会自动纠正出现的错误：
       </p>
       <p>
        <img src="https://realpython.com/images/blog_images/emacs/emacs-elpy-autopep8.gif"/>
       </p>
       <h3>
        IPython/Jupyter集成
       </h3>
       <p>
        接下来这个功能尤其强大：将Emacs与IPython REPL和Jupyter Notebooks集成。首先，我们将Emacs中标准的Python REPL集成替换为IPython版本:
       </p>
       <p>
        现在如果我们按下
        <code>
         C-c C-c
        </code>
        再次运行Python代码，我们使用的将是IPython REPL：
       </p>
       <p>
        <img src="https://realpython.com/images/blog_images/emacs/emacs-elpy-ipython.png"/>
       </p>
       <p>
        尽管做到目前这样已经非常有用了，但是真正的神奇之处还在Emacs与Jupyter notebook之间的集成。这里，我们假设你已经知道如何启动Jupyter Notebook服务器。要实现前面提到的集成，我们只需要再添加一些配置即可：
       </p>
       <div>
        <!-- Crayon Syntax Highlighter v_2.7.2_beta -->
        <div class="crayon-syntax crayon-theme-classic crayon-font-monaco crayon-os-pc print-yes notranslate" data-settings=" minimize scroll-mouseover" id="crayon-576869d6e34bb471644256" style=" margin-top: 12px; margin-bottom: 12px; font-size: 12px !important; line-height: 15px !important;">
         <div class="crayon-toolbar" data-settings=" mouseover overlay hide delay" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
          <span class="crayon-title">
          </span>
          <div class="crayon-tools" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
           <div class="crayon-button crayon-nums-button" title="切换是否显示行编号">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-plain-button" title="纯文本显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-wrap-button" title="切换自动换行">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-expand-button" title="点击展开代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-copy-button" title="复制代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-popup-button" title="在新窗口中显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
          </div>
         </div>
         <div class="crayon-info" style="min-height: 16.8px !important; line-height: 16.8px !important;">
         </div>
         <div class="crayon-plain-wrap">
          <textarea class="crayon-plain print-no" data-settings="dblclick" readonly="" style="-moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4; font-size: 12px !important; line-height: 15px !important;" wrap="soft">
           (defvar myPackages
  '(better-defaults
    ein ;; add the ein package (Emacs ipython notebook)
    elpy
    flycheck
    material-theme
    py-autopep8))
          </textarea>
         </div>
         <div class="crayon-main" style="">
          <table class="crayon-table">
           <tbody>
            <tr class="crayon-row">
             <td class="crayon-nums " data-settings="show">
              <div class="crayon-nums-content" style="font-size: 12px !important; line-height: 15px !important;">
               <div class="crayon-num" data-line="crayon-576869d6e34bb471644256-1">
                1
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34bb471644256-2">
                2
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34bb471644256-3">
                3
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34bb471644256-4">
                4
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34bb471644256-5">
                5
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34bb471644256-6">
                6
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34bb471644256-7">
                7
               </div>
              </div>
             </td>
             <td class="crayon-code">
              <div class="crayon-pre" style="font-size: 12px !important; line-height: 15px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;">
               <div class="crayon-line" id="crayon-576869d6e34bb471644256-1">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 defvar
                </span>
                <span class="crayon-i">
                 myPackages
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34bb471644256-2">
                <span class="crayon-h">
                </span>
                '
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-v">
                 better
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 defaults
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34bb471644256-3">
                <span class="crayon-e">
                </span>
                <span class="crayon-i">
                 ein
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 add
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 ein
                </span>
                <span class="crayon-t">
                 package
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 Emacs
                </span>
                <span class="crayon-e">
                 ipython
                </span>
                <span class="crayon-v">
                 notebook
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34bb471644256-4">
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 elpy
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34bb471644256-5">
                <span class="crayon-e">
                </span>
                <span class="crayon-e">
                 flycheck
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34bb471644256-6">
                <span class="crayon-e">
                </span>
                <span class="crayon-v">
                 material
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 theme
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34bb471644256-7">
                <span class="crayon-e">
                </span>
                <span class="crayon-v">
                 py
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 autopep8
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
              </div>
             </td>
            </tr>
           </tbody>
          </table>
         </div>
        </div>
        <!-- [Format Time: 0.0015 seconds] -->
       </div>
       <p>
        Jupyter提供的notebook网络接口很好，但是要求我们离开Emacs编辑器才能使用：
       </p>
       <p>
        <img src="http://gold.xitu.io/images/loading.png"/>
       </p>
       <p>
        不过，我们可以通过在Emacs中直接连接notebook服务器，并与服务器进行直接交互的方式，就可以完成网络接口所提供的功能。
       </p>
       <p>
        <img src="https://realpython.com/images/blog_images/emacs/emacs-elpy-jupyter.gif"/>
       </p>
       <h2>
        其他Emacs功能
       </h2>
       <p>
        前面我们已经介绍了所有Python IDE应具备的基础功能（以及一些非常棒的额外功能），但是还有一些功能也是IDE需要支持的。首先就是git集成。
       </p>
       <h3>
        Git集成（Magit）
       </h3>
       <p>
        <a href="http://magit.vc/">
         Magit
        </a>
        是MELPA仓库中非常受欢迎的一个插件包，几乎每一个使用Git的Emacs用户都会安装这个插件。这个插件极其强大，功能也特别全面，超出了本文的范围。不过还好
        <a href="https://www.masteringemacs.org/">
         Mastering Emacs网站
        </a>
        上有
        <a href="https://www.masteringemacs.org/article/introduction-magit-emacs-mode-git">
         一篇介绍Magit的好文
        </a>
        。下面这张图就摘自Mastering Emacs网站的那篇文章，展示了Emacs中git集成的效果：
       </p>
       <p>
        <img src="https://realpython.com/images/blog_images/emacs/masteringemacs-magit.png"/>
       </p>
       <h3>
        其他Emacs模式
       </h3>
       <p>
        与使用只针对Python的IDE相比，使用Emacs的一大好处就是它还能够支持除Python外的其他语言。工作的时候，我通常要使用Python、Golang、JavaScript、Markdown、JSON以及其他语言。因此，只使用Emacs编辑器并且完美支持所有这些语言将会大大提高工作效率。Emacs编辑器支持以下语言：
       </p>
       <ul>
        <li>
         Python
        </li>
        <li>
         Golang
        </li>
        <li>
         Ruby
        </li>
        <li>
         Puppet
        </li>
        <li>
         Markdown
        </li>
        <li>
         Dockerfile
        </li>
        <li>
         YAML
        </li>
        <li>
         Web (HTML/JS/CSS)
        </li>
        <li>
         SASS
        </li>
        <li>
         NginX Config
        </li>
        <li>
         SQL
        </li>
       </ul>
       <h3>
        在终端使用Emacs按键组合
       </h3>
       <p>
        学会使用Emacs之后，你会希望在其他地方也能够使用Emacs按键组合。只需要在bash提示符之后输入
        <code>
         set -o emacs
        </code>
        即可实现。但是，Emacs的一个强大之处就是你可以在终端下以headless模式运行Emacs编辑器。这也是我本人的默认终端环境。要开启headless模式，只需要输入
        <code>
         emacs -nw
        </code>
        即可。
       </p>
       <h2>
        结语
       </h2>
       <p>
        正如你所见，Emacs明显是最好的编辑器。老实说，市面上还有其他很好的Python IDE可供选择，但是我会毫不犹豫地推荐你学习Vim或Emacs，因为基于这两个编辑器配置的开发环境无疑是功能最为多样化的。最后，为大家提供本文中完整的Emacs配置：
       </p>
       <div>
        <!-- Crayon Syntax Highlighter v_2.7.2_beta -->
        <div class="crayon-syntax crayon-theme-classic crayon-font-monaco crayon-os-pc print-yes notranslate" data-settings=" minimize scroll-mouseover" id="crayon-576869d6e34c4141305671" style=" margin-top: 12px; margin-bottom: 12px; font-size: 12px !important; line-height: 15px !important;">
         <div class="crayon-toolbar" data-settings=" mouseover overlay hide delay" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
          <span class="crayon-title">
          </span>
          <div class="crayon-tools" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
           <div class="crayon-button crayon-nums-button" title="切换是否显示行编号">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-plain-button" title="纯文本显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-wrap-button" title="切换自动换行">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-expand-button" title="点击展开代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-copy-button" title="复制代码">
            <div class="crayon-button-icon">
            </div>
           </div>
           <div class="crayon-button crayon-popup-button" title="在新窗口中显示代码">
            <div class="crayon-button-icon">
            </div>
           </div>
          </div>
         </div>
         <div class="crayon-info" style="min-height: 16.8px !important; line-height: 16.8px !important;">
         </div>
         <div class="crayon-plain-wrap">
          <textarea class="crayon-plain print-no" data-settings="dblclick" readonly="" style="-moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4; font-size: 12px !important; line-height: 15px !important;" wrap="soft">
           ;; init.el --- Emacs configuration

;; INSTALL PACKAGES
;; --------------------------------------

(require 'package)

(add-to-list 'package-archives
       '("melpa" . "http://melpa.org/packages/") t)

(package-initialize)
(when (not package-archive-contents)
  (package-refresh-contents))

(defvar myPackages
  '(better-defaults
    ein
    elpy
    flycheck
    material-theme
    py-autopep8))

(mapc #'(lambda (package)
    (unless (package-installed-p package)
      (package-install package)))
      myPackages)

;; BASIC CUSTOMIZATION
;; --------------------------------------

(setq inhibit-startup-message t) ;; hide the startup message
(load-theme 'material t) ;; load material theme
(global-linum-mode t) ;; enable line numbers globally

;; PYTHON CONFIGURATION
;; --------------------------------------

(elpy-enable)
(elpy-use-ipython)

;; use flycheck not flymake with elpy
(when (require 'flycheck nil t)
  (setq elpy-modules (delq 'elpy-module-flymake elpy-modules))
  (add-hook 'elpy-mode-hook 'flycheck-mode))

;; enable autopep8 formatting on save
(require 'py-autopep8)
(add-hook 'elpy-mode-hook 'py-autopep8-enable-on-save)

;; init.el ends here
          </textarea>
         </div>
         <div class="crayon-main" style="">
          <table class="crayon-table">
           <tbody>
            <tr class="crayon-row">
             <td class="crayon-nums " data-settings="show">
              <div class="crayon-nums-content" style="font-size: 12px !important; line-height: 15px !important;">
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-1">
                1
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-2">
                2
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-3">
                3
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-4">
                4
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-5">
                5
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-6">
                6
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-7">
                7
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-8">
                8
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-9">
                9
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-10">
                10
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-11">
                11
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-12">
                12
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-13">
                13
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-14">
                14
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-15">
                15
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-16">
                16
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-17">
                17
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-18">
                18
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-19">
                19
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-20">
                20
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-21">
                21
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-22">
                22
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-23">
                23
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-24">
                24
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-25">
                25
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-26">
                26
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-27">
                27
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-28">
                28
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-29">
                29
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-30">
                30
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-31">
                31
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-32">
                32
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-33">
                33
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-34">
                34
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-35">
                35
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-36">
                36
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-37">
                37
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-38">
                38
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-39">
                39
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-40">
                40
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-41">
                41
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-42">
                42
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-43">
                43
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-44">
                44
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-45">
                45
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-46">
                46
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-47">
                47
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-48">
                48
               </div>
               <div class="crayon-num" data-line="crayon-576869d6e34c4141305671-49">
                49
               </div>
               <div class="crayon-num crayon-striped-num" data-line="crayon-576869d6e34c4141305671-50">
                50
               </div>
              </div>
             </td>
             <td class="crayon-code">
              <div class="crayon-pre" style="font-size: 12px !important; line-height: 15px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;">
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-1">
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 init
                </span>
                <span class="crayon-sy">
                 .
                </span>
                <span class="crayon-v">
                 el
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 Emacs
                </span>
                <span class="crayon-i">
                 configuration
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-2">
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-3">
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 INSTALL
                </span>
                <span class="crayon-i">
                 PACKAGES
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-4">
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-5">
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-6">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-i">
                 require
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-s">
                 'package)
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-7">
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-8">
                <span class="crayon-s">
                 (add-to-list '
                </span>
                <span class="crayon-t">
                 package
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 archives
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-9">
                <span class="crayon-h">
                </span>
                <span class="crayon-s">
                 '("melpa" . "http://melpa.org/packages/") t)
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-10">
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-11">
                <span class="crayon-s">
                 (package-initialize)
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-12">
                <span class="crayon-s">
                 (when (not package-archive-contents)
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-13">
                <span class="crayon-s">
                 (package-refresh-contents))
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-14">
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-15">
                <span class="crayon-s">
                 (defvar myPackages
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-16">
                <span class="crayon-s">
                 '
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-v">
                 better
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 defaults
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-17">
                <span class="crayon-e">
                </span>
                <span class="crayon-e">
                 ein
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-18">
                <span class="crayon-e">
                </span>
                <span class="crayon-e">
                 elpy
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-19">
                <span class="crayon-e">
                </span>
                <span class="crayon-e">
                 flycheck
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-20">
                <span class="crayon-e">
                </span>
                <span class="crayon-v">
                 material
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 theme
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-21">
                <span class="crayon-e">
                </span>
                <span class="crayon-v">
                 py
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 autopep8
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-22">
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-23">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-v">
                 mapc
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-p">
                 #'(lambda (package)
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-24">
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 unless
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-t">
                 package
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 installed
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 p
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-t">
                 package
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-25">
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-t">
                 package
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 install
                </span>
                <span class="crayon-t">
                 package
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-26">
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 myPackages
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-27">
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-28">
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 BASIC
                </span>
                <span class="crayon-i">
                 CUSTOMIZATION
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-29">
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
                <span class="crayon-o">
                 --
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-30">
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-31">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 setq
                </span>
                <span class="crayon-v">
                 inhibit
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 startup
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 message
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 t
                </span>
                <span class="crayon-sy">
                 )
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-e">
                 hide
                </span>
                <span class="crayon-e">
                 the
                </span>
                <span class="crayon-e">
                 startup
                </span>
                <span class="crayon-e">
                 message
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-32">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-v">
                 load
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 theme
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-s">
                 'material t) ;; load material theme
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-33">
                <span class="crayon-s">
                 (global-linum-mode t) ;; enable line numbers globally
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-34">
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-35">
                <span class="crayon-s">
                 ;; PYTHON CONFIGURATION
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-36">
                <span class="crayon-s">
                 ;; --------------------------------------
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-37">
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-38">
                <span class="crayon-s">
                 (elpy-enable)
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-39">
                <span class="crayon-s">
                 (elpy-use-ipython)
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-40">
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-41">
                <span class="crayon-s">
                 ;; use flycheck not flymake with elpy
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-42">
                <span class="crayon-s">
                 (when (require '
                </span>
                <span class="crayon-e">
                 flycheck
                </span>
                <span class="crayon-i">
                 nil
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 t
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-43">
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-e">
                 setq
                </span>
                <span class="crayon-v">
                 elpy
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-e">
                 modules
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-i">
                 delq
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-s">
                 'elpy-module-flymake elpy-modules))
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-44">
                <span class="crayon-s">
                 (add-hook '
                </span>
                <span class="crayon-v">
                 elpy
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 mode
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 hook
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-s">
                 'flycheck-mode))
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-45">
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-46">
                <span class="crayon-s">
                 ;; enable autopep8 formatting on save
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-47">
                <span class="crayon-s">
                 (require '
                </span>
                <span class="crayon-v">
                 py
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 autopep8
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-48">
                <span class="crayon-sy">
                 (
                </span>
                <span class="crayon-v">
                 add
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-i">
                 hook
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-s">
                 'elpy-mode-hook '
                </span>
                <span class="crayon-v">
                 py
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 autopep8
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 enable
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 on
                </span>
                <span class="crayon-o">
                 -
                </span>
                <span class="crayon-v">
                 save
                </span>
                <span class="crayon-sy">
                 )
                </span>
               </div>
               <div class="crayon-line" id="crayon-576869d6e34c4141305671-49">
               </div>
               <div class="crayon-line crayon-striped-line" id="crayon-576869d6e34c4141305671-50">
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-sy">
                 ;
                </span>
                <span class="crayon-h">
                </span>
                <span class="crayon-v">
                 init
                </span>
                <span class="crayon-sy">
                 .
                </span>
                <span class="crayon-e">
                 el
                </span>
                <span class="crayon-e">
                 ends
                </span>
                <span class="crayon-v">
                 here
                </span>
               </div>
              </div>
             </td>
            </tr>
           </tbody>
          </table>
         </div>
        </div>
        <!-- [Format Time: 0.0072 seconds] -->
       </div>
       <p>
        希望这些配置能够激起你学习并使用Emacs的热情！
       </p>
      </div>
      <div>
       <strong>
        注：转载文章均来自于公开网络，仅供学习使用，不会用于任何商业用途，如果侵犯到原作者的权益，请您与我们联系删除或者授权事宜，联系邮箱：contact@dataunion.org。转载数盟网站文章请注明原文章作者，否则产生的任何版权纠纷与数盟无关。
       </strong>
      </div>
      <!--content_text-->
      <div class="fenxian">
       <!-- JiaThis Button BEGIN -->
       <div class="jiathis_style_32x32">
        <p class="jiathis_button_weixin">
        </p>
        <p class="jiathis_button_tsina">
        </p>
        <p class="jiathis_button_qzone">
        </p>
        <p class="jiathis_button_cqq">
        </p>
        <p class="jiathis_button_tumblr">
        </p>
        <a class="jiathis jiathis_txt jtico jtico_jiathis" href="http://www.jiathis.com/share" target="_blank">
        </a>
        <p class="jiathis_counter_style">
        </p>
       </div>
       <!-- JiaThis Button END -->
      </div>
     </article>
     <!--content-->
     <!--相关文章-->
     <div class="xianguan">
      <div class="xianguantitle">
       相关文章！
      </div>
      <ul class="pic">
       <li>
        <a href="http://dataunion.org/24678.html">
         <img src="http://dataunion.org/wp-content/uploads/2016/06/20140917125452915416-216x200.jpg"/>
        </a>
        <a class="link" href="http://dataunion.org/24678.html" rel="bookmark" title="python3中的正则模块">
         python3中的正则模块
        </a>
       </li>
       <li>
        <a href="http://dataunion.org/24675.html">
         <img src="http://dataunion.org/wp-content/uploads/2016/06/t015b337bd75d9ef893-161x200.jpg"/>
        </a>
        <a class="link" href="http://dataunion.org/24675.html" rel="bookmark" title="注释是恶魔，请不要再写一行注释">
         注释是恶魔，请不要再写一行注释
        </a>
       </li>
       <li>
        <a href="http://dataunion.org/24660.html">
         <img src="http://dataunion.org/wp-content/uploads/2016/06/u16130037972892789947fm21gp0-300x157.jpg"/>
        </a>
        <a class="link" href="http://dataunion.org/24660.html" rel="bookmark" title="如何从Github上轻松安装R包">
         如何从Github上轻松安装R包
        </a>
       </li>
       <li>
        <a href="http://dataunion.org/24654.html">
         <img src="http://dataunion.org/wp-content/uploads/2016/06/df53fac99fc53ba5a90666abcca25e6d_b-267x200.png"/>
        </a>
        <a class="link" href="http://dataunion.org/24654.html" rel="bookmark" title="简单形象又有趣地说说强大的神经网络">
         简单形象又有趣地说说强大的神经网络
        </a>
       </li>
      </ul>
     </div>
     <!--相关文章-->
     <div class="comment" id="comments">
      <!-- You can start editing here. -->
      <!-- If comments are open, but there are no comments. -->
      <div class="title">
       期待你一针见血的评论，Come on！
      </div>
      <div id="respond">
       <p>
        不用想啦，马上
        <a href="http://dataunion.org/wp-login.php?redirect_to=http%3A%2F%2Fdataunion.org%2F24134.html">
         "登录"
        </a>
        发表自已的想法.
       </p>
      </div>
     </div>
     <!-- .nav-single -->
    </div>
    <!--Container End-->
    <aside id="sitebar">
     <div class="sitebar_list2">
      <div class="wptag">
       <span class="tagtitle">
        热门标签+
       </span>
       <div class="tagg">
        <ul class="menu" id="menu-%e5%8f%8b%e6%83%85%e9%93%be%e6%8e%a5">
         <li class="menu-item menu-item-type-custom menu-item-object-custom menu-item-1605" id="menu-item-1605">
          <a href="http://taidizh.com/">
           泰迪智慧
          </a>
         </li>
         <li class="menu-item menu-item-type-custom menu-item-object-custom menu-item-20884" id="menu-item-20884">
          <a href="http://www.transwarp.cn/">
           星环科技
          </a>
         </li>
         <li class="menu-item menu-item-type-custom menu-item-object-custom menu-item-3538" id="menu-item-3538">
          <a href="http://datall.org/">
           珈和遥感
          </a>
         </li>
         <li class="menu-item menu-item-type-custom menu-item-object-custom menu-item-20888" id="menu-item-20888">
          <a href="http://www.chinahadoop.cn/">
           小象学院
          </a>
         </li>
        </ul>
       </div>
      </div>
     </div>
     <div class="sitebar_list">
      <div class="textwidget">
       <div align="center">
        <a href="http://study.163.com/course/courseMain.htm?courseId=991022" target="_blank">
         <img src="http://dataunion.org/wp-content/uploads/2016/03/dv.jpg"/>
        </a>
       </div>
      </div>
     </div>
     <div class="sitebar_list">
      <h4 class="sitebar_title">
       文章分类
      </h4>
      <div class="tagcloud">
       <a class="tag-link-44" href="http://dataunion.org/category/industry/demo" style="font-size: 10.204724409449pt;" title="4个话题">
        Demo展示
       </a>
       <a class="tag-link-31" href="http://dataunion.org/category/experts" style="font-size: 15.826771653543pt;" title="52个话题">
        专家团队
       </a>
       <a class="tag-link-870" href="http://dataunion.org/category/tech/ai" style="font-size: 19.795275590551pt;" title="273个话题">
        人工智能
       </a>
       <a class="tag-link-488" href="http://dataunion.org/category/%e5%8a%a0%e5%85%a5%e6%95%b0%e7%9b%9f" style="font-size: 8pt;" title="1个话题">
        加入数盟
       </a>
       <a class="tag-link-869" href="http://dataunion.org/category/tech/viz" style="font-size: 17.204724409449pt;" title="93个话题">
        可视化
       </a>
       <a class="tag-link-30" href="http://dataunion.org/category/partners" style="font-size: 10.645669291339pt;" title="5个话题">
        合作伙伴
       </a>
       <a class="tag-link-889" href="http://dataunion.org/category/parterc" style="font-size: 11.582677165354pt;" title="8个话题">
        合作会议
       </a>
       <a class="tag-link-104" href="http://dataunion.org/category/books" style="font-size: 12.96062992126pt;" title="15个话题">
        图书
       </a>
       <a class="tag-link-220" href="http://dataunion.org/category/tech/base" style="font-size: 19.850393700787pt;" title="281个话题">
        基础架构
       </a>
       <a class="tag-link-219" href="http://dataunion.org/category/tech/analysis" style="font-size: 19.409448818898pt;" title="232个话题">
        数据分析
       </a>
       <a class="tag-link-887" href="http://dataunion.org/category/tech/dm" style="font-size: 13.291338582677pt;" title="17个话题">
        数据挖掘
       </a>
       <a class="tag-link-34" href="http://dataunion.org/category/tech" style="font-size: 20.732283464567pt;" title="404个话题">
        文章
       </a>
       <a class="tag-link-1" href="http://dataunion.org/category/uncategorized" style="font-size: 22pt;" title="693个话题">
        未分类
       </a>
       <a class="tag-link-4" href="http://dataunion.org/category/events" style="font-size: 14.503937007874pt;" title="29个话题">
        活动
       </a>
       <a class="tag-link-890" href="http://dataunion.org/category/tech/%e6%b7%b1%e5%ba%a6%e5%ad%a6%e4%b9%a0" style="font-size: 10.204724409449pt;" title="4个话题">
        深度学习
       </a>
       <a class="tag-link-221" href="http://dataunion.org/category/tech/devl" style="font-size: 18.968503937008pt;" title="193个话题">
        编程语言
       </a>
       <a class="tag-link-888" href="http://dataunion.org/category/career" style="font-size: 15.661417322835pt;" title="48个话题">
        职业规划
       </a>
       <a class="tag-link-5" href="http://dataunion.org/category/jobs" style="font-size: 14.11811023622pt;" title="25个话题">
        职位
       </a>
       <a class="tag-link-871" href="http://dataunion.org/category/industry" style="font-size: 15.716535433071pt;" title="49个话题">
        行业
       </a>
       <a class="tag-link-613" href="http://dataunion.org/category/industry/case" style="font-size: 16.984251968504pt;" title="84个话题">
        行业应用
       </a>
       <a class="tag-link-885" href="http://dataunion.org/category/industry/news" style="font-size: 17.425196850394pt;" title="102个话题">
        行业资讯
       </a>
       <a class="tag-link-10" href="http://dataunion.org/category/training" style="font-size: 14.228346456693pt;" title="26个话题">
        课程
       </a>
       <a class="tag-link-16" href="http://dataunion.org/category/sources" style="font-size: 15.661417322835pt;" title="48个话题">
        资源
       </a>
      </div>
     </div>
     <div class="sitebar_list">
      <h4 class="sitebar_title">
       功能
      </h4>
      <ul>
       <li>
        <a href="http://dataunion.org/wp-login.php?action=register">
         注册
        </a>
       </li>
       <li>
        <a href="http://dataunion.org/wp-login.php">
         登录
        </a>
       </li>
       <li>
        <a href="http://dataunion.org/feed">
         文章
         <abbr title="Really Simple Syndication">
          RSS
         </abbr>
        </a>
       </li>
       <li>
        <a href="http://dataunion.org/comments/feed">
         评论
         <abbr title="Really Simple Syndication">
          RSS
         </abbr>
        </a>
       </li>
       <li>
        <a href="https://cn.wordpress.org/" title="基于WordPress，一个优美、先进的个人信息发布平台。">
         WordPress.org
        </a>
       </li>
      </ul>
     </div>
    </aside>
    <div class="clear">
    </div>
   </div>
   <!--main-->
   ﻿
   <footer id="dibu">
    <div class="about">
     <div class="right">
      <ul class="menu" id="menu-%e5%ba%95%e9%83%a8%e8%8f%9c%e5%8d%95">
       <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-18024" id="menu-item-18024">
        <a href="http://dataunion.org/category/partners">
         合作伙伴
        </a>
       </li>
       <li class="menu-item menu-item-type-post_type menu-item-object-page menu-item-20881" id="menu-item-20881">
        <a href="http://dataunion.org/contribute">
         文章投稿
        </a>
       </li>
       <li class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-20872" id="menu-item-20872">
        <a href="http://dataunion.org/category/%e5%8a%a0%e5%85%a5%e6%95%b0%e7%9b%9f">
         加入数盟
        </a>
       </li>
       <li class="menu-item menu-item-type-post_type menu-item-object-page menu-item-22441" id="menu-item-22441">
        <a href="http://dataunion.org/f-links">
         友情链接
        </a>
       </li>
       <li class="menu-item menu-item-type-post_type menu-item-object-page menu-item-20874" id="menu-item-20874">
        <a href="http://dataunion.org/aboutus">
         关于数盟
        </a>
       </li>
      </ul>
      <p class="banquan">
       数盟社区        ，
        做最棒的数据科学社区
      </p>
     </div>
     <div class="left">
      <ul class="bottomlist">
       <li>
        <a href="http://weibo.com/DataScientistUnion  " target="_blank" 　title="">
         <img src="http://dataunion.org/wp-content/themes/yzipi/images/weibo.png"/>
        </a>
       </li>
       <li>
        <a class="cd-popup-trigger" href="http://dataunion.org/24134.html#0">
         <img src="http://dataunion.org/wp-content/themes/yzipi/images/weixin.png"/>
        </a>
       </li>
      </ul>
      <div class="cd-popup">
       <div class="cd-popup-container">
        <h1>
         扫描二维码,加微信公众号
        </h1>
        <img src="http://dataunion.org/wp-content/themes/yzipi/images/2014-12-06-1515289049.png"/>
        <a class="cd-popup-close" href="http://dataunion.org/24134.html">
        </a>
       </div>
       <!-- cd-popup-container -->
      </div>
      <!-- cd-popup -->
     </div>
    </div>
    <!--about-->
    <div class="bottom">
     <a href="http://dataunion.org/">
      数盟社区
     </a>
     <a href="http://www.miitbeian.gov.cn/" rel="external nofollow" target="_blank">
      京ICP备14026740号
     </a>
     联系我们：
     <a href="mailto:contact@dataunion.org" target="_blank">
      contact@dataunion.org
     </a>
     <div class="tongji">
     </div>
     <!--bottom-->
     <div class="scroll" id="scroll" style="display:none;">
      ︿
     </div>
    </div>
   </footer>
   <!--dibu-->
  </div>
 </body>
</html>